<!--{eval $_TPL['titles'] = array('公司');}-->
<!--{template header}-->

<!-- main -->
<div class="tab" id="comp_list">
	<div id="mainarea">
		<div class="tabs_header">
			<ul class="tabs">
				<li class="active"><a href="cp.php?ac=business"><span>发布货盘信息</span></a></li>
				<li><a href="space.php?do=business"><span>返回信息列表</span></a></li>
			</ul>
		</div>

<!--{if $op == "delete"}-->
	<div>
		<form method="post" name="eventform" action="cp.php?ac=business&op=delete&id=$infoid">
			<h1>您确定取消此活动吗？</h1>
			<p>活动取消将删除所有活动相关信息。<br />此操作不可恢复！</p>
			<p class="btn_line"><br />
				<input type="hidden" name="refer" value="$_SGLOBAL[refer]">
				<input type="submit" name="deletesubmit" value="确定" class="submit" />
				<input type="button" name="btnclose" value="取消" onclick="hideMenu();" class="button" />
			</p>
			<input type="hidden" name="formhash" value="<!--{eval echo formhash();}-->" />
		</form>
	</div>
<!--{else}-->
	<div class="c_form">
		<form id="edit_form" name="edit_form" method="post" enctype="multipart/form-data" action="cp.php?ac=business&op=edit&id=$infoid">
			<table class="infotable" width="100%" cellspacing="6" cellpadding="6" >	
				<tbody>
					<tr>
						<th>信息标题</th>
						<td>
							<input class="t_input" id="title" name="title" value="$cargo[title]" size="45" type="text" maxlength="80"><font color="red">&nbsp;&nbsp;*</font>
						</td>
					</tr>
					<tr>
						<th>贸易类型</th>
						<td>
							<select name="inout" id="inout" >
								<option value="1"  {if $cargo[value]==1 } selected {/if}>外贸货盘</option>
								<option value="2"  {if $cargo[value]==2 } selected {/if}>内贸货盘</option>
							</select><font color="red">&nbsp;&nbsp;*</font>
						</td>
					</tr>
					<tr>
						<th>货物名称</th>
						<td>
							<input class="t_input" id="name" name="name" value="$cargo[name]" size="45" type="text" maxlength="80"><font color="red">&nbsp;&nbsp;*</font>
						</td>
					</tr>
					<tr>
						<th>货物数量</th>
						<td colspan="2">
							<input class="t_input" id="num" name="num" value="$cargo[num]" size="8" type="text" >
							<select name="value" id="value" >
								<option value="1">MT公吨</option>
								<option value="2">CBM立方米</option>
							</select><font color="red">&nbsp;&nbsp;*</font>
						</td>
					</tr>

					<tr>
						<th>积载因数</th>
						<td>
							<input class="t_input" id="stow" name="stow" value="$cargo[stow]" size="20" type="text" maxlength="80">
						</td>
					</tr>
				
					<tr>
						<th>装船港口</th>
						<td>
							<input class="t_input" id="loadport" name="loadport" value="$cargo[loadport]" size="20" type="text" maxlength="80"><font color="red">&nbsp;&nbsp;*</font>
						</td>
					</tr>
					<tr>
						<th>卸船港口</th>
						<td>
							<input class="t_input" id="destin" name="destin" value="$cargo[destin]" size="20" type="text" maxlength="80"><font color="red">&nbsp;&nbsp;*</font>
						</td>
					</tr>
					<tr>
						<th>所在地区 </th>
						<td id="citybox">
							<script type="text/javascript" src="source/script_city.js" charset="$_SC[charset]"></script>
							<script type="text/javascript" charset="$_SC[charset]">
								showprovince('province', 'city', '$cargo[province]', 'citybox');
								showcity('city', '$cargo[city]', 'province', 'citybox');
							</script>
						</td>
					</tr>
					<tr>
						<th>托运时间</th>
						<td>
							<script type="text/javascript" src="source/script_calendar.js" charset="$_SC[charset]"></script>
							<input type="text" name="starttime" id="starttime" value="<!--{eval echo sgmdate('Y-m-d H:i', $cargo[statrtime])}-->"  onclick="showcalendar(business,this,1,'<!--{eval echo sgmdate('Y-m-d H:i', $_SGLOBAL[timestamp])}-->', '<!--{eval echo sgmdate('Y-m-d H:i', $_SGLOBAL[timestamp] + 3600 * 24 * 60)}-->')" />
						 至
							<input type="text" name="endtime" id="endtime" value="<!--{eval echo sgmdate('Y-m-d H:i', $cargo[endtime])}-->"  onclick="showcalendar(business,this,1,'<!--{eval echo sgmdate('Y-m-d H:i', $_SGLOBAL[timestamp])}-->', '<!--{eval echo sgmdate('Y-m-d H:i', $_SGLOBAL[timestamp] + 3600 * 24 * 60)}-->')" /><font color="red">&nbsp;&nbsp;*</font>
						</td>
					</tr>

					<tr>
						<th>托运/包装形式</th>
						<td>
							<select name="pack" id="pack" >
								<option value="1"  {if $cargo[pack]==1 } selected {/if}>散装</option>
								<option value="2"  {if $cargo[pack]==2 } selected {/if}>袋装</option>
								<option value="3"  {if $cargo[pack]==3 } selected {/if}>桶装</option>
								<option value="4"  {if $cargo[pack]==4 } selected {/if}>其它</option>
							</select><font color="red">&nbsp;&nbsp;*</font>
						</td>
					</tr>
					<tr>
						<th>公司名称/个人姓名</th>
						<td>
							<input class="t_input" id="company" name="company" value="$cargo[company]" size="45" type="text" maxlength="80"><font color="red">&nbsp;&nbsp;*</font>
						</td>
					</tr>
					<tr>
						<th>联系人</th>
						<td>
							<input class="t_input" id="linkman" name="linkman" value="$cargo[linkman]" size="20" type="text" maxlength="80"><font color="red">&nbsp;&nbsp;*</font>
						</td>
					</tr>
					<tr>
						<th>联系电话</th>
						<td>
							<input class="t_input" id="phone" name="phone" value="$cargo[phone]" size="20" type="text" maxlength="80"><font color="red">&nbsp;&nbsp;*</font>
						</td>
					</tr>
					<tr>
						<th>传   真 </th>
						<td>
							<input class="t_input" id="fax" name="fax" value="$cargo[fax]" size="20" type="text" maxlength="80">
						</td>
					</tr>
					<tr>
						<th>邮   箱 </th>
						<td>
							<input class="t_input" id="email" name="email" value="$cargo[email]" size="20" type="text" maxlength="80">
						</td>
					</tr>
					<tr>
						<th>备   注</th>
						<td colspan="2">
						<textarea class="userData" name="remark" cols="50" rows="8">$cargo[remark]</textarea></td>
					</tr>
				</tbody>
			</table>
			<!--{if checkperm('seccode')}-->
			<table class="infotable" width="100%" cellspacing="6" cellpadding="6">
				<tbody>
				<!--{if $_SCONFIG['questionmode']}-->
				<tr>
					<th width="100" style="vertical-align: top;">请回答验证问题</th>
					<td>
						<p><!--{eval question();}--></p>
						<input type="text" id="seccode" name="seccode" value="" size="15" class="t_input" />
					</td>
				</tr>
				<!--{else}-->
				<tr>
					<th width="100" style="vertical-align: top;">请填写验证码</th>
					<td>
						<script type="text/javascript" charset="$_SC[charset]">seccode();</script>
						<p>请输入上面的4位字母或数字，看不清可<a href="javascript:updateseccode()">更换一张</a></p>
						<input type="text" id="seccode" name="seccode" value="" size="15" class="t_input" />
					</td>
				</tr>
				<!--{/if}-->
				</tbody>
			</table>
			<!--{/if}-->
			<table class="infotable" width="100%" cellspacing="4" cellpadding="4">
				<tbody>
					<tr>
						<th width="100">&nbsp;</th>
						<td>
							<input type="hidden" name="formhash" value="<!--{eval echo formhash();}-->" />
							<input type="hidden" name="bnid" value="$id" />
							<input type="hidden" name="infosubmit" value="1" />
							<input class="submit" value="<!--{if $_GET[id]}-->保存<!--{else}-->提交<!--{/if}-->" type="button" onclick="check_eventpost()"/>
						</td>
					</tr>
				</tbody>
			</table>
		</form>
	</div>
<!--{/if}-->
	<script type="text/javascript" src="image/editor/editor_function.js" charset="$_SC[charset]"></script>
	<script type="text/javascript" charset="$_SC[charset]">
		//检查提交
		function check_eventpost(){
			$("edit_form").submit();
		}
	</script>
</div>
</div>
<!--{template footer}-->